cmake_minimum_required(VERSION 3.5)
project(DesignPattern)

set(CMAKE_CXX_STANDARD 11)

set(SOURCE_FILES main.cpp
        SimpleFactory/Product.h
        SimpleFactory/AfProductA.cpp
        SimpleFactory/ProductA.h
        SimpleFactory/AfProductB.cpp
        SimpleFactory/ProductB.h
        SimpleFactory/AfFactory.cpp
        SimpleFactory/Factory.h

        FactoryMethod/Factory.h
        FactoryMethod/Product.h
        FactoryMethod/FileLog.cpp
        FactoryMethod/FileLog.h
        FactoryMethod/DatabaseLog.cpp
        FactoryMethod/DatabaseLog.h
        FactoryMethod/DatabaseFactory.cpp
        FactoryMethod/DatabaseFactory.h
        FactoryMethod/FileFactory.cpp
        FactoryMethod/FileFactory.h

        AbstractFactory/AfProductA.h
        AbstractFactory/AfFactory.h
        AbstractFactory/AfProductB.h
        AbstractFactory/AfProductA1.cpp
        AbstractFactory/AfProductA1.h
        AbstractFactory/AfProductA2.cpp
        AbstractFactory/AfProductA2.h
        AbstractFactory/AfProductB1.cpp
        AbstractFactory/AfProductB1.h
        AbstractFactory/AfProductB2.cpp
        AbstractFactory/AfProductB2.h
        AbstractFactory/AfFactory1.cpp
        AbstractFactory/AfFactory1.h
        AbstractFactory/AfFactory2.cpp
        AbstractFactory/AfFactory2.h

        Builder/BProduct.h
        Builder/BDirector.cpp
        Builder/BDirector.h
        Builder/BBuilder.h
        Builder/BConcreteBuilder.cpp
        Builder/BConcreteBuilder.h
        Builder/BConcreteProduct.cpp
        Builder/BConcreteProduct.h

        Singleton/Singleton.cpp
        Singleton/Singleton.h

        Adapter/IFormatIPhone.h
        Adapter/IFormatAndroid.h
        Adapter/ICharger.h
        Adapter/Charger.cpp
        Adapter/Charger.h
        Adapter/IPhone.cpp
        Adapter/IPhone.h
        Adapter/Android.cpp
        Adapter/Android.h
        Adapter/AndroidAdpater.cpp
        Adapter/AndroidAdpater.h
        Adapter/IPhoneAdapter.cpp
        Adapter/IPhoneAdapter.h

        Bridge/DrawingApi.h
        Bridge/DrawCircle.cpp
        Bridge/DrawCircle.h
        Bridge/DrawRectangle.cpp
        Bridge/DrawRectangle.h
        Bridge/IColor.h
        Bridge/Red.cpp
        Bridge/Red.h
        Bridge/Blue.cpp
        Bridge/Blue.h

        Facade/Cpu.cpp
        Facade/Cpu.h
        Facade/HardDrive.cpp
        Facade/HardDrive.h
        Facade/Memory.cpp
        Facade/Memory.h
        Facade/Computer.cpp
        Facade/Computer.h

        Proxy/Subject.h
        Proxy/RealSubject.cpp
        Proxy/RealSubject.h
        Proxy/Proxy.cpp
        Proxy/Proxy.h

        Command/Invoker.cpp
        Command/Invoker.h
        Command/Command.h
        Command/ConcreteCommand.cpp
        Command/ConcreteCommand.h
        Command/Receiver.cpp
        Command/Receiver.h

        Mediator/Colleague.h
        Mediator/Mediator.h
        Mediator/ConcreteMediator.cpp
        Mediator/ConcreteMediator.h
        Mediator/ConcreteColleagueA.cpp
        Mediator/ConcreteColleagueA.h
        Mediator/ConcreteColleagueB.cpp
        Mediator/ConcreteColleagueB.h

        Observer/Subject.h
        Observer/Observer.h
        Observer/ConcreteObserver.cpp
        Observer/ConcreteObserver.h
        Observer/ConcreteSubject.cpp
        Observer/ConcreteSubject.h

        State/Context.cpp
        State/Context.h
        State/State.h
        State/ConcreteStateA.cpp
        State/ConcreteStateA.h
        State/ConcreteStateB.cpp
        State/ConcreteStateB.h

        Strategy/Context.cpp
        Strategy/Context.h
        Strategy/Strategy.h
        Strategy/ConcreteStrategyA.cpp
        Strategy/ConcreteStrategyA.h
        Strategy/ConcreteStrategyB.cpp
        Strategy/ConcreteStrategyB.h

        Decorator/Window.h
        Decorator/SimpleWindow.cpp
        Decorator/SimpleWindow.h
        Decorator/DecoratedWindow.cpp
        Decorator/DecoratedWindow.h
        Decorator/ScrollableWindow.cpp
        Decorator/ScrollableWindow.h Observer/Subject.cpp)
add_executable(DesignPattern ${SOURCE_FILES})